/*
 * @Author: 45F
 * @LastEditors  : Hasbug
 * @Description: 路由页
 * @Date: 2019-07-06 11:03:19
 * @LastEditTime : 2020-01-19 23:39:41
 * @LastEditTime: 2019-10-28 16:19:45
 */
import Main from "@/components/main";
// import RouterRoot from "@/components/router-root";

/**
 * meta: {
 *  hideInMenu: (false) 设为true后菜单不会显示该页面选项
 *  hideOfChildren: (false) 设为true后菜单不会显示该路由下的children
 *  activeInMenu: (name) 设为hideInMenu为true的页面可设置该选项，指向某路由name，点亮该菜单选项
 *  moreInMenu: (name) 设为true后页面会放在更多菜单下的子菜单
 * }
 */

export default [
  {
    path: "/login",
    name: "login",
    meta: {
      hideInMenu: true
    },
    component: () => import("@/views/login")
  },
  {
    path: "/updatePassword",
    name: "updatePassword",
    meta: {
      hideInMenu: true
    },
    component: () => import("@/components/updatePassword/updatePassword.vue")
  },
  {
    path: "/",
    name: "",
    redirect: {
      name: "data_exchange_home"
    },
    meta: {
      hideInMenu: true
    }
  },
  {
    path: "/data_exchange",
    name: "data_exchange",
    redirect: {
      name: "data_exchange_home"
    },
    component: Main,
    children: [
      {
        path: "home",
        name: "data_exchange_home",
        meta: {
          title: "首页",
          activeInMenu: "/data_exchange/home"
        },
        component: () => import("@/views/page/home.vue")
      },
      {
        path: "zcmx",
        name: "data_exchange_zcmx",
        meta: {
          title: "资产明细",
          activeInMenu: "/data_exchange/zcmx"
        },
        component: () => import("@/views/page/zcmx.vue")
      },
      {
        path: "zcmx_detail",
        name: "data_exchange_zcmx_detail",
        meta: {
          title: "资产明细详情",
          activeInMenu: "/data_exchange/zcmx_detail"
        },
        component: () => import("@/views/page/zcmx_detail.vue")
      },
      {
        path: "zyqq",
        name: "data_exchange_zyqq",
        meta: {
          title: "资源请求",
          activeInMenu: "/data_exchange/zyqq"
        },
        component: () => import("@/views/page/zyqq.vue")
      },
      {
        path: "zyqq_home",
        name: "data_exchange_zyqq_home",
        meta: {
          title: "资源请求",
          activeInMenu: "/data_exchange/zyqq_home"
        },
        component: () => import("@/views/page/zyqq_home.vue")
      },
      {
        path: "xfjl",
        name: "data_exchange_xfjl",
        meta: {
          title: "消费记录",
          activeInMenu: "/data_exchange/xfjl"
        },
        component: () => import("@/views/page/xfjl.vue")
      },
      {
        path: "xfjl_home",
        name: "data_exchange_xfjl_home",
        meta: {
          title: "消费记录",
          activeInMenu: "/data_exchange/xfjl_home"
        },
        component: () => import("@/views/page/xfjl_home.vue")
      },
      {
        path: "xfjl_detail",
        name: "data_exchange_xfjl_detail",
        meta: {
          title: "消费记录",
          activeInMenu: "/data_exchange/xfjl_detail"
        },
        component: () => import("@/views/page/xfjl_detail.vue")
      },
      {
        path: "yhgl",
        name: "data_exchange_yhgl",
        meta: {
          title: "用户管理",
          activeInMenu: "/data_exchange/yhgl"
        },
        component: () => import("@/views/page/yhgl.vue")
      },
      {
        path: "jsgl",
        name: "data_exchange_jsgl",
        meta: {
          title: "角色管理",
          activeInMenu: "/data_exchange/jsgl"
        },
        component: () => import("@/views/page/jsgl.vue")
      }
    ]
  }
];
